package com.espirit.eap.manager;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;

import com.googlecode.cswish.model.Saas;

/**
 * Command example:<p>
 * 1) Number type:
 * <br>
 * 2) Expression:
 * <li>1:00 am every day (night): 0 0 1 * * ?
 * <li>each 5 second: 5 * * * * ?
 * <li>each 1 hour: 0 0 * * * ? 
 * 
 * @author Jerry.Feng
 *
 */
@Entity
public class TaskScheduler implements Saas{

	private Integer id;
	
	private String name;
	
	private Boolean active;
	
	private String cond;
	
	private String command;
	
	private String description;
	
	private Integer sid;
	public Integer getSid() {
		return sid;
	}

	public void setSid(Integer sid) {
		this.sid = sid;
	}

	@Id
	@GeneratedValue
	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	@Column(nullable=false)
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public Boolean getActive() {
		return active;
	}

	public void setActive(Boolean active) {
		this.active = active;
	}

	@Column(nullable=false)
	public String getCond() {
		return cond;
	}

	public void setCond(String cond) {
		this.cond = cond;
	}

	public String getCommand() {
		return command;
	}

	public void setCommand(String command) {
		this.command = command;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}
}
